home *** CD-ROM | disk | FTP | other *** search
-
-
- Instructions for Using GLUT with Mesa
-
-
- Mark Kilgard's GLUT (OpenGL Utility Toolkit) is a toolkit for quickly
- and easily writing OpenGL demos and applications.
-
- GLUT has been used successfully with Mesa on many systems. If you have
- problems contact Brian Paul if you think the problem is caused by Mesa.
- Contact Mark Kilgard, or post to the Mesa mailing list, if you think the
- problem is in GLUT.
-
- At the time of Mesa's 2.0 release the latest version of GLUT is 3.1
-
-
- Here's how to get GLUT and build it using Mesa:
-
- 1. Use your WWW browser to open the URL:
- http://reality.sgi.com/employees/mjk_asd/glut3/glut3.html
-
- Under "About the GLUT source code distribution" is a link to the
- distribution file glut-3.1.tar.Z Click on it to download GLUT.
-
- 2. In your shell, move glut-3.1.tar.Z into the Mesa-2.x directory and
- unpack it with:
- zcat glut.3.1.tar.Z | tar xvf -
-
- 3. cd to the GLUT directory:
- cd glut-3.1
-
- 4. Make a backup copy of Glut.cf:
- cp Glut.cf Glut.cf.orig
-
- 5. Make sure GLut.cf is writable since we have to edit it:
- chmod +w Glut.cf
-
- 6. If you're using a Sun with Solaris then define the following two
- environment variables from your shell:
-
- OGLHOME to where you've installed Mesa (like /usr/home/brian/Mesa)
- OPENWINHOME to something like /usr/openwin
-
- 7. Edit Glut.cf as follows. Note that there are two places where these
- changes may have to be made depending on whether you're using a Sun
- or not.
-
- change: EXTRA_INCLUDES = -I$(TOP)
- to look like: EXTRA_INCLUDES = -I$(TOP)/../include -I$(TOP)
-
- change: OPENGL = -lGL
- to look like: OPENGL = $(TOP)/../lib/libMesaGL.a
-
- change: GLU = -lGLU
- to look like: GLU = $(TOP)/../lib/libMesaGLU.a
-
- NOTE: if you made shared Mesa libraries, the suffixes might be .so instead
- of .a
-
- 8. Run the mkmkfiles.imake script:
- mkmkfiles.imake
-
- 9. Run make:
- make
-
- 10. If all goes well there should be many executables in the progs/
- directories for you to try out.
-
- 11. You may want to copy the lib/glut/libglut.a file to wherever you have
- your Mesa libraries (libMesaGL.a, libMesaGLU.a, etc) if you're going to
- use it for your own work.
-